<?php

namespace app\models\db;

use Yii;

/**
 * This is the model class for table "t_zfb_trade_record".
 *
 * @property string $id
 * @property string $notify_time
 * @property string $notify_type
 * @property string $notify_id
 * @property string $app_id
 * @property string $charset
 * @property string $version
 * @property string $sign_type
 * @property string $sign
 * @property string $trade_no
 * @property string $out_trade_no
 * @property string $out_biz_no
 * @property string $buyer_id
 * @property string $buyer_logon_id
 * @property string $seller_id
 * @property string $seller_email
 * @property string $trade_status
 * @property string $total_amount
 * @property string $receipt_amount
 * @property string $invoice_amount
 * @property string $buyer_pay_amount
 * @property string $point_amount
 * @property string $refund_fee
 * @property string $subject
 * @property string $body
 * @property string $gmt_create
 * @property string $gmt_payment
 * @property string $gmt_refund
 * @property string $gmt_close
 * @property string $fund_bill_list
 * @property string $passback_params
 * @property string $voucher_detail_list
 */
class ZfbTradeRecord extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 't_zfb_trade_record';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['id'], 'required'],
            [['notify_time', 'gmt_create', 'gmt_payment', 'gmt_refund', 'gmt_close'], 'safe'],
            [['sign'], 'string'],
            [['total_amount', 'receipt_amount', 'invoice_amount', 'buyer_pay_amount', 'point_amount', 'refund_fee'], 'number'],
            [['id'], 'string', 'max' => 36],
            [['notify_type', 'trade_no', 'out_trade_no', 'out_biz_no'], 'string', 'max' => 64],
            [['notify_id'], 'string', 'max' => 128],
            [['app_id', 'trade_status'], 'string', 'max' => 32],
            [['charset', 'sign_type'], 'string', 'max' => 10],
            [['version'], 'string', 'max' => 3],
            [['buyer_id'], 'string', 'max' => 16],
            [['buyer_logon_id', 'seller_email'], 'string', 'max' => 100],
            [['seller_id'], 'string', 'max' => 30],
            [['subject'], 'string', 'max' => 256],
            [['body'], 'string', 'max' => 400],
            [['fund_bill_list', 'passback_params', 'voucher_detail_list'], 'string', 'max' => 512],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'notify_time' => 'Notify Time',
            'notify_type' => 'Notify Type',
            'notify_id' => 'Notify ID',
            'app_id' => 'App ID',
            'charset' => 'Charset',
            'version' => 'Version',
            'sign_type' => 'Sign Type',
            'sign' => 'Sign',
            'trade_no' => 'Trade No',
            'out_trade_no' => 'Out Trade No',
            'out_biz_no' => 'Out Biz No',
            'buyer_id' => 'Buyer ID',
            'buyer_logon_id' => 'Buyer Logon ID',
            'seller_id' => 'Seller ID',
            'seller_email' => 'Seller Email',
            'trade_status' => 'Trade Status',
            'total_amount' => 'Total Amount',
            'receipt_amount' => 'Receipt Amount',
            'invoice_amount' => 'Invoice Amount',
            'buyer_pay_amount' => 'Buyer Pay Amount',
            'point_amount' => 'Point Amount',
            'refund_fee' => 'Refund Fee',
            'subject' => 'Subject',
            'body' => 'Body',
            'gmt_create' => 'Gmt Create',
            'gmt_payment' => 'Gmt Payment',
            'gmt_refund' => 'Gmt Refund',
            'gmt_close' => 'Gmt Close',
            'fund_bill_list' => 'Fund Bill List',
            'passback_params' => 'Passback Params',
            'voucher_detail_list' => 'Voucher Detail List',
        ];
    }
}
